package site.wetsion.employ.server.pojo;

import java.io.Serializable;
import java.math.BigInteger;
import java.sql.Timestamp;
/**
 * 论坛帖子类
 * @author Wetsion
 *
 */
public class ForumPost implements Serializable, Comparable<ForumPost> {

	private static final long serialVersionUID = 1L;
	
	private BigInteger id;
	
	private String post_title;
	
	private String post_content;
	
	private BigInteger post_starter_id;
	
	private int post_status;
	
	private Timestamp gmt_create;
	
	private Timestamp gmt_modified;
	
	private User post_starter;

	public User getPost_starter() {
		return post_starter;
	}

	public void setPost_starter(User post_starter) {
		this.post_starter = post_starter;
	}

	public BigInteger getId() {
		return id;
	}

	public void setId(BigInteger id) {
		this.id = id;
	}

	public String getPost_title() {
		return post_title;
	}

	public void setPost_title(String post_title) {
		this.post_title = post_title;
	}

	public String getPost_content() {
		return post_content;
	}

	public void setPost_content(String post_content) {
		this.post_content = post_content;
	}

	public BigInteger getPost_starter_id() {
		return post_starter_id;
	}

	public void setPost_starter_id(BigInteger post_starter_id) {
		this.post_starter_id = post_starter_id;
	}

	public int getPost_status() {
		return post_status;
	}

	public void setPost_status(int post_status) {
		this.post_status = post_status;
	}

	public Timestamp getGmt_create() {
		return gmt_create;
	}

	public void setGmt_create(Timestamp gmt_create) {
		this.gmt_create = gmt_create;
	}

	public Timestamp getGmt_modified() {
		return gmt_modified;
	}

	public void setGmt_modified(Timestamp gmt_modified) {
		this.gmt_modified = gmt_modified;
	}

	
	/**
	 * 按照帖子修改时间来排序
	 */
	@Override
	public int compareTo(ForumPost o) {
		return gmt_modified.compareTo(o.getGmt_modified());
	}
	
	

}
